#include "HUD.h"

void HUD::InitFont(abfw::Platform& platform_)
{
	font_ = new abfw::Font();
	font_->Load("comic_sans", platform_);
}

void HUD::Draw(abfw::SpriteRenderer* sprite_renderer_, float v[])
{
	if(font_)
	{
		font_->RenderText(sprite_renderer_, abfw::Vector3(850.0f, 510.0f, -0.9f), 1.0f, 0xffffffff, abfw::TJ_LEFT, "FPS: %.1f", v[0]);
		font_->RenderText(sprite_renderer_, abfw::Vector3(-0, -0, -0.9f), 1.0f, 0xffffffff, abfw::TJ_LEFT, "Found: %d", v[1]);

	}
}

void HUD::CleanUpFont()
{
	delete font_;
	font_ = NULL;
}